import Http from "@/http";

export function saveApi(params:any) {
    return params.id ? Http.put('deviceType/update', params) : Http.post('deviceType/add', params)
}


export function deleteApi(id) {
    return Http.delete('deviceType/delete/' + id)
}


export function listApi() {
    return Http.get('deviceType/list')
}

export function deviceTypeOptionsApi() {
    return Http.get('deviceType/options')
}

export function getParamsFieldApi(id:number) {
    return Http.get('deviceType/paramsField/' + id)
}



export function getDeviceTypeApi(id) {
    return Http.get('deviceType/detail/' + id)
}